/**
 * Author: Daniel Michalski
 * Date: 25.02.13
 */

public class WildCardDemo {
    public static void main(String[] args) {
        Integer inums[] = { 1, 2, 3, 4, 5 };
        Stats<Integer> iob = new Stats<Integer>(inums);
        double v = iob.average();
        System.out.println("Srednia iob wynosi " + v);

        Double dnums[] = { 1.1, 2.2, 3.3, 4.4, 5.5 };
        Stats<Double> dob = new Stats<Double>(dnums);
        double w = dob.average();
        System.out.println("Srednia dob wynosi " + w);

        Float fnums[] = { 1.0F, 2.0F, 3.0F, 4.0F, 5.0F };
        Stats<Float> fob = new Stats<Float>(fnums);
        double x = fob.average();
        System.out.println("Srednia fob wynosi " + x);


        System.out.print("Srednie iob i dob są ");
        if (iob.sameAvg(dob))
            System.out.println("takie same");
        else
            System.out.println("różne");

        System.out.print("Srednie iob i fob są ");
        if (iob.sameAvg(fob))
            System.out.println("takie same");
        else
            System.out.println("różne");
    }
}
